package com.member.shop.vo;

import com.baomidou.mybatisplus.annotation.TableField;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.member.common.annotation.Excel;
import com.member.common.core.domain.BaseEntity;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.experimental.SuperBuilder;

import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

/**
 * 用户列对象 sys_biz_user
 *
 * @author lixinchen
 * @date 2024-01-03
 */
@Data
@SuperBuilder
@AllArgsConstructor
@NoArgsConstructor
public class SysBizUserVo extends BaseEntity {

    private static final long serialVersionUID = 1L;

    /**
     * 用户主键id
     */
    private Long id;

    /**
     * 用户唯一id
     */
    @Excel(name = "用户唯一id")
    private String bizId;

    /**
     * unionid
     */
    @Excel(name = "unionid")
    private String unionid;

    /**
     * openId
     */
    @Excel(name = "openId")
    private String openId;


    /**
     * 头像
     */
    @Excel(name = "头像")
    private String avatar;

    /**
     * 姓名
     */
    @Excel(name = "姓名")
    private String fullName;

    /**
     * 昵称
     */
    private String nickName;

    /**
     * 登录手机号
     */
    @Excel(name = "手机号")
    private String userPhone;

    /**
     * 会员手机号
     */
    private String memberPhone;

    /**
     * 店铺名称
     */
    @TableField(exist = false)
    private String shopName;


    /**
     * 状态: 0 启用 1禁用
     */
    @Excel(name = "状态: 0 启用 1禁用")
    private Integer displayed;

    /**
     * 邀请码
     */
    @Excel(name = "邀请码")
    private String invitationCode;

    /**
     * 身份证正面
     */
    @Excel(name = "身份证正面")
    private String idCardFront;

    /**
     * 身份证反面
     */
    @Excel(name = "身份证反面")
    private String idCardBack;

    /**
     * 是否注册会员 0未注册 1已注册
     */
    private Integer isRegisterMember;

    /**
     * 审核状态(1.待审核，2.审核通过，3.审核驳回)
     */
    @Excel(name = "审核状态(1.待审核，2.审核通过，3.审核驳回)")
    private Integer processStatus;

    /**
     * 审核时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "审核时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    private Date processTime;

    /**
     * 驳回原因
     */
    @Excel(name = "驳回原因")
    private String rejectReason;

    /**
     * 会员等级id
     */
    @Excel(name = "会员等级id")
    private Long memberGradeId;


    /**
     * 会员等级名称
     */
    @Excel(name = "会员等级名称")
    private String memberGradeName;

    /**
     * 已提现余额
     */
    @Excel(name = "已提现余额")
    private BigDecimal withdrawnBalance;

    /**
     * 未提现余额
     */
    @Excel(name = "未提现余额")
    private BigDecimal unwithdrawnBalance;

    /**
     * 充值余额
     */
    @Excel(name = "充值余额")
    private BigDecimal rechargeBalance;

    /**
     * 可发展会员人数
     */
    @Excel(name = "可发展会员人数")
    private Long availableMembers;

    /**
     * 已发展会员人数
     */
    @Excel(name = "已发展会员人数")
    private Long developedMembers;

    /**
     * 用户身份(0:非会员,1:会员 2 销售人员)
     */
    @Excel(name = "用户身份(0:非会员,1:会员 )")
    private Integer userRole;

    /**
     * 绑定时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "绑定时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    private Date bindTime;

    /**
     * 核实状态
     */
    @Excel(name = "核实状态")
    private Integer verifyStatus;

    /**
     * 核实时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "核实时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    private Date verifyTime;

    /**
     * 上级id
     */
    @Excel(name = "上级id")
    private Long parentId;


    /**
     * 备注
     */
    @Excel(name = "备注")
    private String remark;

    /**
     * 创建时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    private Date createTime;

    /**
     * 小程序token
     */
    @TableField(exist = false)
    private String token;


    /**
     * 上级人数
     */
    @TableField(exist = false)
    private Long upNum = 0L;

    /**
     * 下级人数
     */
    @TableField(exist = false)
    private Long  downNum = 0L;

    /**
     * 上级
     */
    @TableField(exist = false)
    private List<Long> upList ;

    @TableField(exist = false)
    private String parentUserName;

    @TableField(exist = false)
    private String parentPhone;
    /**
     * 余额
     */
    private BigDecimal surplus;

    /**
     * 是否销售（0.不是销售，1.销售）
     */
    private Integer isSale;



    @TableField(exist = false)
    private String salesPhone;

    @TableField(exist = false)
    private String salesName;
}
